package sg.edu.nus.iss.jass.dto;

import java.util.List;

import sg.edu.nus.iss.jass.datastore.BaseDTO;
import sg.edu.nus.iss.jass.util.Util;

public class JobResponse extends BaseDTO {

	private String address;

	private String email;
	
	private JobAdvert jobAdvert;
	
	private String jobAdvertId;

	private JobSeeker jobSeeker;

	private String jobSeekerId;
	
	private String telephoneNo;

	private List<Skill> skill;

	private String skillIds;

	private Resume resume;

	private String resumeId;

	private Action action;

	private String actionId;
	
	private float currentSalary;
	private float expectedSalary;
	

	/**
	 * @return the jobAdvert
	 */
	public JobAdvert getJobAdvert() {
		return jobAdvert;
	}

	/**
	 * @param jobAdvert the jobAdvert to set
	 */
	public void setJobAdvert(JobAdvert jobAdvert) {
		this.jobAdvert = jobAdvert;
	}

	/**
	 * @return the jobAdvertId
	 */
	public String getJobAdvertId() {
		if(jobAdvert != null){
			return jobAdvert.getId();
		}
		if(!Util.isEmpty(jobAdvertId)) {
			return jobAdvertId;
		}
		return null;
	}

	/**
	 * @param jobAdvertId the jobAdvertId to set
	 */
	public void setJobAdvertId(String jobAdvertId) {
		this.jobAdvertId = jobAdvertId;
	}

	/**
	 * @return the address
	 */
	public String getAddress() {

		return address;
	}

	/**
	 * @param address the address to set
	 */
	public void setAddress(String address) {

		this.address = address;
	}

	/**
	 * @return the email
	 */
	public String getEmail() {

		return email;
	}

	/**
	 * @param email the email to set
	 */
	public void setEmail(String email) {

		this.email = email;
	}

	/**
	 * @return the jobSeeker
	 */
	public JobSeeker getJobSeeker() {

		return jobSeeker;
	}

	/**
	 * @param jobSeeker the jobSeeker to set
	 */
	public void setJobSeeker(JobSeeker jobSeeker) {

		this.jobSeeker = jobSeeker;
	}

	/**
	 * @return the jobSeekerId
	 */
	public String getJobSeekerId() {
		if(jobSeeker != null){
			return jobSeeker.getId();
		}
		if(!Util.isEmpty(jobSeekerId)) {
			return jobSeekerId;
		}
		return null;
	}

	/**
	 * @param jobSeekerId the jobSeekerId to set
	 */
	public void setJobSeekerId(String jobSeekerId) {

		this.jobSeekerId = jobSeekerId;
	}

	/**
	 * @return the telephoneNo
	 */
	public String getTelephoneNo() {

		return telephoneNo;
	}

	/**
	 * @param telephoneNo the telephoneNo to set
	 */
	public void setTelephoneNo(String telephoneNo) {

		this.telephoneNo = telephoneNo;
	}

	/**
	 * @return the skill
	 */
	public List<Skill> getSkill() {

		return skill;
	}

	/**
	 * @param skill the skill to set
	 */
	public void setSkill(List<Skill> skill) {

		this.skill = skill;
	}

	/**
	 * @return the skillIds
	 */
	public String getSkillIds() {

		if(!Util.isEmpty(skill)){
			return super.getIds(skill);
		}
		if(!Util.isEmpty(skillIds)) {
			return skillIds;
		}
		return null;
		
	}

	/**
	 * @param skillIds the skillIds to set
	 */
	public void setSkillIds(String skillIds) {

		this.skillIds = skillIds;
	}

	/**
	 * @return the resume
	 */
	public Resume getResume() {

		return resume;
	}

	/**
	 * @param resume the resume to set
	 */
	public void setResume(Resume resume) {

		this.resume = resume;
	}

	/**
	 * @return the resumeId
	 */
	public String getResumeId() {
		if(resume != null){
			return resume.getId();
		}
		if(!Util.isEmpty(resumeId)) {
			return resumeId;
		}
		return null;
	}

	/**
	 * @param resumeId the resumeId to set
	 */
	public void setResumeId(String resumeId) {

		this.resumeId = resumeId;
	}

	/**
	 * @return the action
	 */
	public Action getAction() {

		return action;
	}

	/**
	 * @param action the action to set
	 */
	public void setAction(Action action) {

		this.action = action;
	}

	/**
	 * @return the actionId
	 */
	public String getActionId() {
		
		if(action != null){
			return action.getId();
		}
		if(!Util.isEmpty(actionId)) {
			return actionId;
		}
		return null;
	}

	/**
	 * @param actionId the actionId to set
	 */
	public void setActionId(String actionId) {

		this.actionId = actionId;
	}
	
	/**
	 * @return the currentSalary
	 */
	public float getCurrentSalary() {
	
		return currentSalary;
	}

	
	/**
	 * @param currentSalary the currentSalary to set
	 */
	public void setCurrentSalary(float currentSalary) {
	
		this.currentSalary = currentSalary;
	}
	

	/**
	 * @return the expectedSalary
	 */
	public float getExpectedSalary() {
	
		return expectedSalary;
	}

	
	/**
	 * @param expectedSalary the expectedSalary to set
	 */
	public void setExpectedSalary(float expectedSalary) {
	
		this.expectedSalary = expectedSalary;
	}
	

	

}
